package com.rslai.base.tool.servertest.model;

public class ServiceDesc {
    private String id;
    private String service;
    private String desc;
    private Integer count;
    private Integer successCount;
    private Long totalSuccessDuration;

    public Integer getSuccessCount() {
        return this.successCount;
    }

    public void setSuccessCount(Integer successCount) {
        this.successCount = successCount;
    }

    public Long getTotalSuccessDuration() {
        return this.totalSuccessDuration;
    }

    public void setTotalSuccessDuration(Long totalSuccessDuration) {
        this.totalSuccessDuration = totalSuccessDuration;
    }

    public ServiceDesc(String id, String service, String desc) {
        this.id = id;
        this.service = service;
        this.desc = desc;
        this.count = Integer.valueOf(0);
        this.successCount = Integer.valueOf(0);
        this.totalSuccessDuration = Long.valueOf(0L);
    }

    public void called() {
        this.count = Integer.valueOf(this.count.intValue() + 1);
    }

    public String getId() {
        return this.id;
    }

    public String getService() {
        return this.service;
    }

    public String getDesc() {
        return this.desc;
    }

    public Integer getCount() {
        return this.count;
    }

    public void callSuccess() {
        this.successCount = Integer.valueOf(this.successCount.intValue() + 1);
    }

    public void addDuration(Long duration) {
        ServiceDesc servicedesc = this;
        servicedesc.totalSuccessDuration = Long.valueOf(servicedesc.totalSuccessDuration.longValue() + duration.longValue());
    }
}
